﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;

namespace TPIntegrador
{
    public partial class _Default : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void Login_Authenticate(object sender, AuthenticateEventArgs e)
        {
            bool Autenticado = false;
            Autenticado = LoginCorrecto(Login.UserName, Login.Password);
            e.Authenticated = Autenticado;
            if (Autenticado)
            {
                Response.Redirect("forms/Home.aspx");
            }
        }

        private bool LoginCorrecto(string Usuario, string Contrasena)
        {
            if (Usuario.Equals("user") && Contrasena.Equals("pass"))
            {
                return true;
            }
            return false;
        }
    }
}
